<!-- Menu Toggle Button -->
<a href="#" class="dropdown-toggle" data-toggle="dropdown">

  {{#if islogin}}
  <!-- The user image in the navbar-->
  <img src="../static/libs/user2-160x160.jpg" class="user-image" alt="User Image">
  <!-- hidden-xs hides the username on small devices so only the image appears. -->
  <span class="hidden-xs">{{username}}</span>
  {{else}}
  <span class="hidden-xs" id="login">登录</span>
  <span class="hidden-xs" id="signin">注册</span>

  {{/if}}

</a>
<ul class="dropdown-menu">

  {{#if islogin}}

  <!-- The user image in the menu -->
  <li class="user-header">
    <img src="../static/libs/user2-160x160.jpg" class="img-circle" alt="User Image">

    <p>
      欢迎登录
      <small>admin</small>
    </p>
  </li>
  <!-- Menu Body -->
  <!-- Menu Footer-->
  <li class="user-footer">
    <div class="pull-left">
      <a href="#" class="btn btn-default btn-flat">取消</a>
    </div>
    <div class="pull-right">
      <a href="#" class="btn btn-default btn-flat" id="btn_logout">退出</a>
    </div>
  </li>
  {{else}}
  <li>
    <div class="box-header with-border">
      <h3 class="box-title">登录</h3>
    </div>
    <form role="form" id="user-form">
      <div class="box-body">
        <div class="form-group">
          <label for="exampleInputEmail1">账号：</label>
          <input class="form-control" name="username" placeholder="Enter Username">
        </div>
        <div class="form-group">
          <label for="exampleInputPassword1">密码：</label>
          <input type="password" class="form-control" name="password" placeholder="Enter Password">
        </div>

      </div>
      <!-- /.box-body -->


    </form>
  </li>

  <li class="user-footer">
    <div class="pull-left">
      <a href="#" class="btn btn-default btn-flat">取消</a>
    </div>
    <div class="pull-right">
      <a href="#" class="btn btn-default btn-flat" id="btn_submit">确定</a>
    </div>
  </li>
  {{/if}}

</ul>